package BIZ;


import DAO.TotalFeeDAO;

public class totalFeeBiz {
    TotalFeeDAO totalFeeDAO = new TotalFeeDAO();

    //更改总收入
    public int


    aadincome(String income) {
        int allincome = getallincome();
        int newallincome = allincome + Integer.parseInt(income);
        int aadincome = totalFeeDAO.changeTotalIncome(newallincome);
        return aadincome;
    }


    //更改总退款
    public int subincome(String income) {
        int allrefund = getallrefund();
        int newallrefund = allrefund + Integer.parseInt(income);
        int subincome = totalFeeDAO.changeRefund(newallrefund);
        return subincome;
    }

    //更改总月卡收入
    public int allmonthincome(String income) {
        int allmonthincome = getallmonthincome();
        int newallmonthincome = allmonthincome + Integer.parseInt(income);
        int x = totalFeeDAO.changeMonthIncome(newallmonthincome);
        return x;
    }


    //更改总次卡收入
    public int alldegreeincome(String income) {
        int alldegreeincome = getalldegreeincome();
        int newalldegreeincome = alldegreeincome + Integer.parseInt(income);
        int x = totalFeeDAO.changeTimeIncome(newalldegreeincome);
        return x;
    }

    //得到目前所有月卡收入
    public int getallmonthincome() {
        int allmonthincome = totalFeeDAO.getMonthIncome();
        return allmonthincome;
    }

    //得到目前所有次卡收入
    public int getalldegreeincome() {
        int alldegreeincome = totalFeeDAO.getTimesIncome();
        return alldegreeincome;
    }



    //得到目前所有收入
    public int getallincome() {
        int allincome = totalFeeDAO.getTotalFee();
        return allincome;
    }

    //得到目前所有退款数额
    public int getallrefund() {
        int allincome = totalFeeDAO.getRefund();
        return allincome;
    }

}
